/*
 * Decompiled with CFR 0.150.
 * 
 * Could not load the following classes:
 *  cn.hutool.core.collection.CollUtil
 *  cn.hutool.core.util.ObjectUtil
 *  com.alibaba.fastjson.JSON
 *  de.felixroske.jfxsupport.FXMLController
 *  javafx.beans.value.ChangeListener
 *  javafx.beans.value.ObservableValue
 *  javafx.collections.FXCollections
 *  javafx.collections.ObservableList
 *  javafx.event.ActionEvent
 *  javafx.fxml.FXML
 *  javafx.fxml.Initializable
 *  javafx.scene.Node
 *  javafx.scene.control.Alert
 *  javafx.scene.control.Alert$AlertType
 *  javafx.scene.control.Button
 *  javafx.scene.control.ComboBox
 *  javafx.scene.control.TableCell
 *  javafx.scene.control.TableColumn
 *  javafx.scene.control.TableView
 *  javafx.scene.control.TextField
 *  javafx.scene.control.cell.PropertyValueFactory
 *  javafx.scene.layout.AnchorPane
 *  javafx.scene.text.Text
 *  javafx.stage.Modality
 *  javafx.util.Callback
 *  javafx.util.StringConverter
 *  org.springframework.beans.BeanUtils
 *  org.springframework.beans.factory.annotation.Autowired
 */
package com.gys.controller.returnDepot;

import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.ObjectUtil;
import com.alibaba.fastjson.JSON;
import com.gys.GysApplication;
import com.gys.common.business.DepotUtil;
import com.gys.common.data.HttpJson;
import com.gys.common.data.KeyValue;
import com.gys.common.util.CacheUtil;
import com.gys.common.util.CommonUtil;
import com.gys.controller.BaseController;
import com.gys.controller.clearBox.ClearProductQueryController;
import com.gys.controller.dataManger.ControllerManger;
import com.gys.controller.returnDepot.DepotController;
import com.gys.controller.salesReceipts.TipTopController;
import com.gys.data.accept.ProductOutData;
import com.gys.data.example.GetLoginStoreOutData;
import com.gys.data.returnDepot.GetDepotDetailOutData;
import com.gys.data.returnDepot.GetDepotInData;
import com.gys.data.returnDepot.GetDepotOutData;
import com.gys.data.returnDepot.GetDepotProductExportInData;
import com.gys.view.returnDepot.ChooseProduct;
import de.felixroske.jfxsupport.FXMLController;
import java.io.File;
import java.lang.reflect.Method;
import java.math.BigDecimal;
import java.net.URL;
import java.util.ArrayList;
import java.util.List;
import java.util.ResourceBundle;
import javafx.beans.value.ChangeListener;
import javafx.beans.value.ObservableValue;
import javafx.collections.FXCollections;
import javafx.collections.ObservableList;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.Node;
import javafx.scene.control.Alert;
import javafx.scene.control.Button;
import javafx.scene.control.ComboBox;
import javafx.scene.control.TableCell;
import javafx.scene.control.TableColumn;
import javafx.scene.control.TableView;
import javafx.scene.control.TextField;
import javafx.scene.control.cell.PropertyValueFactory;
import javafx.scene.layout.AnchorPane;
import javafx.scene.text.Text;
import javafx.stage.Modality;
import javafx.util.Callback;
import javafx.util.StringConverter;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;

@FXMLController
public class AddDepotController
extends BaseController
implements Initializable {
    @FXML
    private TableView<GetDepotDetailOutData> tableView;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddSerial;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddProId;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proName;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proPrice;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddBatchNo;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddBatch;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddValidDate;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddStockQty;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddRetdepQty;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddRetdepCause;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddStartQty;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddReviseQty;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> gsrddStockStatus;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proFactoryName;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proPlace;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proForm;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proUnit;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proSpecs;
    @FXML
    private TableColumn<GetDepotDetailOutData, String> proRegisterNo;
    @FXML
    private TextField storeText;
    @FXML
    private TextField storeText1;
    @FXML
    private Button addBtn;
    @FXML
    private Button save;
    @FXML
    private Button print;
    @FXML
    private Button approve1;
    @FXML
    private Button approve2;
    @FXML
    private Button exportIn;
    @FXML
    private Button exportOut;
    @FXML
    private AnchorPane pane;
    @Autowired
    private DepotController depotController;
    @Autowired
    private TipTopController tipTopController;
    @Autowired
    private ClearProductQueryController clearProductQueryController;
    private ObservableList<GetDepotDetailOutData> observableTableList = FXCollections.observableArrayList(new ArrayList());
    public ObservableList<KeyValue> gsegNameOptions;
    private ObservableList<KeyValue> reasonOptions;
    private String status;
    private String voucherId;

    public void initialize(URL location, ResourceBundle resources) {
        ControllerManger.controllerMap.put(this.getClass().getSimpleName(), this);
        ArrayList<KeyValue> reasonOptionList = new ArrayList<KeyValue>();
        reasonOptionList.add(new KeyValue("\u6ede\u9500\u8c03\u5e93", "1"));
        reasonOptionList.add(new KeyValue("\u8d28\u91cf\u95ee\u9898", "2"));
        reasonOptionList.add(new KeyValue("\u5230\u8d27\u5dee\u5f02", "3"));
        this.reasonOptions = FXCollections.observableArrayList(reasonOptionList);
        this.bingDetailTableCell();
        this.init();
    }

    @Override
    public void init() {
        if (ObjectUtil.isEmpty(this.pane)) {
            return;
        }
        this.storeText.setText(((GetLoginStoreOutData)CacheUtil.get("store")).getStoName());
        this.storeText1.setText(((GetLoginStoreOutData)CacheUtil.get("store")).getStoName());
        if (ObjectUtil.isNotEmpty(this.depotController.voucherId)) {
            this.tipTopController.initTitle("\u5ba1\u6838\u9000\u5e93\u8bb0\u5f55");
            GetDepotInData inData = new GetDepotInData();
            inData.setStoreCode(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode());
            inData.setGsrdhVoucherId(this.depotController.voucherId);
            inData.setGsrdhBrId(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode());
            HttpJson httpJson = DepotUtil.detail(inData);
            GetDepotOutData data = new GetDepotOutData();
            if (httpJson.isSuccess()) {
                data = (GetDepotOutData)JSON.parseObject((String)httpJson.getMsg(), GetDepotOutData.class);
                this.voucherId = data.getGsrdhVoucherId();
                this.status = data.getGsrdhStatus();
                if ("1".equals(data.getGsrdhStatus())) {
                    if (data.getGsrdhFrom().equals(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode())) {
                        this.approve1.setDisable(false);
                    } else {
                        this.approve1.setDisable(true);
                    }
                    this.approve2.setDisable(true);
                    this.print.setDisable(true);
                    this.addBtn.setVisible(false);
                    this.save.setVisible(true);
                    this.exportIn.setVisible(false);
                    this.exportOut.setVisible(false);
                    this.changeToTextFieldDEdit(this.gsrddStartQty);
                    this.gsrddRetdepQty.setVisible(true);
                    this.gsrddReviseQty.setVisible(true);
                } else if ("3".equals(data.getGsrdhStatus())) {
                    this.approve1.setDisable(true);
                    if (data.getGsrdhFrom().equals(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode())) {
                        this.approve2.setDisable(false);
                    } else {
                        this.approve2.setDisable(true);
                    }
                    this.print.setDisable(false);
                    this.addBtn.setVisible(false);
                    this.save.setVisible(false);
                    this.exportIn.setVisible(false);
                    this.exportOut.setVisible(false);
                    this.changeToTextFieldDEdit(this.gsrddRetdepQty);
                    this.gsrddRetdepQty.setVisible(true);
                    this.gsrddReviseQty.setVisible(true);
                    this.clearEdit(this.gsrddStartQty);
                } else {
                    this.approve1.setDisable(true);
                    this.approve2.setDisable(true);
                    this.print.setDisable(false);
                    this.addBtn.setVisible(false);
                    this.save.setVisible(false);
                    this.exportIn.setVisible(false);
                    this.exportOut.setVisible(false);
                    this.gsrddRetdepQty.setVisible(true);
                    this.gsrddReviseQty.setVisible(true);
                    this.clearEdit(this.gsrddStartQty);
                }
                this.observableTableList = FXCollections.observableArrayList(data.getDepotDetailInDataList());
                this.initTable();
            } else {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", httpJson.getMsg());
                alert.showAndWait();
            }
        } else {
            this.tipTopController.initTitle("\u65b0\u589e\u9000\u5e93\u8bb0\u5f55");
            this.approve1.setDisable(true);
            this.approve2.setDisable(true);
            this.print.setDisable(true);
            this.addBtn.setVisible(true);
            this.save.setVisible(true);
            this.exportIn.setVisible(true);
            this.exportOut.setVisible(true);
            this.gsrddRetdepQty.setVisible(false);
            this.gsrddReviseQty.setVisible(false);
            this.status = "0";
            this.observableTableList.clear();
        }
    }

    public void comboxInit(ComboBox box) {
        box.converterProperty().set(new StringConverter<KeyValue>(){

            public String toString(KeyValue object) {
                return object.getName();
            }

            public KeyValue fromString(String string) {
                return null;
            }
        });
    }

    public TableView<GetDepotDetailOutData> initTable() {
        this.bingDetailTableCell();
        this.tableView.setItems(this.observableTableList);
        return this.tableView;
    }

    @FXML
    private void choose() {
        GysApplication.showView(ChooseProduct.class, (Modality)Modality.APPLICATION_MODAL);
    }

    @FXML
    public TableView<GetDepotDetailOutData> addProduct(ProductOutData product) {
        GetDepotDetailOutData data = new GetDepotDetailOutData();
        int index = this.observableTableList.size();
        data.setGsrddSerial(String.valueOf(index + 1));
        data.setGsrddProId(product.getProCode());
        data.setGsrddValidDate(product.getProLife());
        data.setProFactoryName(product.getProFactoryName());
        data.setProForm(product.getProForm());
        data.setProName(product.getGspgProName());
        data.setProPlace(product.getProPlace());
        data.setProRegisterNo(product.getProRegisterNo());
        data.setProSpecs(product.getGspgSpecs());
        data.setProUnit(product.getProUnit());
        data.setProPrice(product.getProPrice());
        data.setGsrddValidDate(product.getValidDate());
        data.setGsrddBatch(product.getBatch());
        data.setGsrddBatchNo(product.getBatchNo());
        data.setGsrddStockQty(product.getStockQty());
        this.observableTableList.add(data);
        this.bingDetailTableCell();
        this.changeToReasonComBoxEdit(this.gsrddRetdepCause, this.reasonOptions);
        this.changeToTextFieldDEdit(this.gsrddStartQty);
        this.gsrddRetdepQty.setVisible(false);
        this.gsrddReviseQty.setVisible(false);
        this.tableView.setItems(this.observableTableList);
        return this.tableView;
    }

    @FXML
    private void exportOut() {
        CommonUtil.exportModelFile("\u9000\u5e93\u5bfc\u5165\u6a21\u677f", "/modelFile/depotProductModelFile.xls");
    }

    @FXML
    private void exportIn() throws Exception {
        File file = CommonUtil.fileChooser();
        if (ObjectUtil.isEmpty(file)) {
            return;
        }
        Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", null);
        List<GetDepotProductExportInData> importExcelInData = CommonUtil.importExcel(file, 0, GetDepotProductExportInData.class);
        if (CollUtil.isEmpty(importExcelInData)) {
            alert.setContentText("\u6ca1\u6709\u6709\u6548\u6570\u636e");
            alert.showAndWait();
            return;
        }
        GetDepotInData inData = new GetDepotInData();
        inData.setStoreCode(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode());
        ArrayList<GetDepotDetailOutData> dataList = new ArrayList<GetDepotDetailOutData>();
        for (GetDepotProductExportInData importData : importExcelInData) {
            GetDepotDetailOutData detailInData = new GetDepotDetailOutData();
            BeanUtils.copyProperties(importData, detailInData);
            dataList.add(detailInData);
        }
        inData.setDepotDetailInDataList(dataList);
        HttpJson rsp = DepotUtil.exportIn(inData);
        if (rsp.isSuccess()) {
            List<ProductOutData> list = JSON.parseArray((String)rsp.getMsg(), ProductOutData.class);
            for (ProductOutData product : list) {
                GetDepotDetailOutData data = new GetDepotDetailOutData();
                int index = this.observableTableList.size();
                data.setGsrddSerial(String.valueOf(index + 1));
                data.setGsrddProId(product.getProCode());
                data.setProFactoryName(product.getProFactoryName());
                data.setProForm(product.getProForm());
                data.setProName(product.getGspgProName());
                data.setProPlace(product.getProPlace());
                data.setProRegisterNo(product.getProRegisterNo());
                data.setProSpecs(product.getGspgSpecs());
                data.setProUnit(product.getProUnit());
                data.setProPrice(product.getProPrice());
                data.setGsrddValidDate(product.getValidDate());
                data.setGsrddBatch(product.getBatch());
                data.setGsrddBatchNo(product.getBatchNo());
                data.setGsrddStockQty(product.getStockQty());
                data.setGsrddStartQty(product.getAllotQty());
                this.observableTableList.add(data);
                this.changeToTextFieldDEdit(this.gsrddStartQty);
                this.initTable();
            }
        } else {
            alert.setContentText(rsp.getMsg());
            alert.showAndWait();
        }
    }

    @FXML
    private void sureAction() {
        if (this.observableTableList.size() == 0) {
            Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u8bf7\u6dfb\u52a0\u5546\u54c1");
            alert.showAndWait();
            return;
        }
        for (int i = 0; i < this.observableTableList.size(); ++i) {
            if (ObjectUtil.isEmpty(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddStartQty())) {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u53d1\u8d77\u6570\u91cf\u8bf7\u586b\u5199\u5b8c\u6574");
                alert.showAndWait();
                return;
            }
            if (new BigDecimal(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddStartQty()).compareTo(new BigDecimal(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddStockQty())) <= 0) continue;
            Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u53d1\u8d77\u6570\u91cf\u4e0d\u80fd\u5927\u4e8e\u5e93\u5b58\u6570\u91cf");
            alert.showAndWait();
            return;
        }
        if ("0".equals(this.status)) {
            GetDepotInData inData = new GetDepotInData();
            inData.setGsrdhType("1");
            inData.setStoreCode(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode());
            inData.setDepotDetailInDataList((List<GetDepotDetailOutData>)this.observableTableList);
            HttpJson httpJson = DepotUtil.insert(inData);
            if (httpJson.isSuccess()) {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u4fdd\u5b58\u6210\u529f");
                alert.showAndWait();
                this.cancelAction();
                this.depotController.initTable(0);
            } else {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", httpJson.getMsg());
                alert.showAndWait();
            }
        } else {
            GetDepotInData inData = new GetDepotInData();
            inData.setGsrdhType("1");
            inData.setStoreCode(((GetLoginStoreOutData)CacheUtil.get("store")).getStoCode());
            inData.setGsrdhVoucherId(this.voucherId);
            inData.setDepotDetailInDataList((List<GetDepotDetailOutData>)this.observableTableList);
            HttpJson httpJson = DepotUtil.update(inData);
            if (httpJson.isSuccess()) {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u4fdd\u5b58\u6210\u529f");
                alert.showAndWait();
                this.cancelAction();
                this.depotController.initTable(0);
            } else {
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", httpJson.getMsg());
                alert.showAndWait();
            }
        }
    }

    @FXML
    private void approve() {
        HttpJson httpJson;
        GetDepotInData inData = new GetDepotInData();
        inData.setGsrdhVoucherId(this.depotController.voucherId);
        if ("1".equals(this.status)) {
            inData.setGsrdhStatus("2");
        }
        if ("3".equals(this.status)) {
            for (int i = 0; i < this.observableTableList.size(); ++i) {
                if (ObjectUtil.isEmpty(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddRetdepQty())) {
                    Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u9000\u5e93\u6570\u91cf\u8bf7\u586b\u5199\u5b8c\u6574");
                    alert.showAndWait();
                    return;
                }
                if (new BigDecimal(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddRetdepQty()).compareTo(new BigDecimal(((GetDepotDetailOutData)this.observableTableList.get(i)).getGsrddStartQty())) <= 0) continue;
                Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u9000\u5e93\u6570\u91cf\u4e0d\u80fd\u5927\u4e8e\u53d1\u8d77\u6570\u91cf");
                alert.showAndWait();
                return;
            }
            inData.setGsrdhStatus("4");
        }
        if ((httpJson = DepotUtil.approve(inData)).isSuccess()) {
            Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", "\u5ba1\u6838\u6210\u529f!");
            alert.showAndWait();
            this.cancelAction();
            this.depotController.initTable(0);
        } else {
            Alert alert = this.createAlert(Alert.AlertType.INFORMATION, "\u63d0\u793a\u4fe1\u606f", httpJson.getMsg());
            alert.showAndWait();
        }
    }

    private void bingDetailTableCell() {
        this.gsrddSerial.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddSerial.getId()));
        this.gsrddProId.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddProId.getId()));
        this.proName.setCellValueFactory((Callback)new PropertyValueFactory(this.proName.getId()));
        this.proPrice.setCellValueFactory((Callback)new PropertyValueFactory(this.proPrice.getId()));
        this.gsrddBatchNo.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddBatchNo.getId()));
        this.gsrddBatch.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddBatch.getId()));
        this.gsrddValidDate.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddValidDate.getId()));
        this.gsrddStockQty.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddStockQty.getId()));
        this.gsrddRetdepQty.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddRetdepQty.getId()));
        this.gsrddRetdepCause.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddRetdepCause.getId()));
        this.gsrddStartQty.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddStartQty.getId()));
        this.gsrddReviseQty.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddReviseQty.getId()));
        this.proFactoryName.setCellValueFactory((Callback)new PropertyValueFactory(this.proFactoryName.getId()));
        this.proPlace.setCellValueFactory((Callback)new PropertyValueFactory(this.proPlace.getId()));
        this.proForm.setCellValueFactory((Callback)new PropertyValueFactory(this.proForm.getId()));
        this.proUnit.setCellValueFactory((Callback)new PropertyValueFactory(this.proUnit.getId()));
        this.proSpecs.setCellValueFactory((Callback)new PropertyValueFactory(this.proSpecs.getId()));
        this.proRegisterNo.setCellValueFactory((Callback)new PropertyValueFactory(this.proRegisterNo.getId()));
        this.gsrddStockStatus.setCellValueFactory((Callback)new PropertyValueFactory(this.gsrddStockStatus.getId()));
    }

    @FXML
    private void cancelAction() {
        this.clearComBoxEdit(this.gsrddRetdepCause);
        this.clearEdit(this.gsrddRetdepQty);
        this.observableTableList.clear();
        this.pane.getScene().getWindow().hide();
    }

    public void clearEdit(TableColumn<GetDepotDetailOutData, String> column) {
        column.setCellFactory(tc -> {
            TableCell<GetDepotDetailOutData, String> cell = new TableCell<GetDepotDetailOutData, String>(){

                protected void updateItem(String chuzhi, boolean empty) {
                    super.updateItem(chuzhi, empty);
                    if (empty) {
                        this.setGraphic(null);
                    } else {
                        Text text = new Text();
                        text.setText(chuzhi);
                        this.setGraphic((Node)text);
                    }
                }
            };
            return cell;
        });
    }

    public void clearComBoxEdit(TableColumn<GetDepotDetailOutData, String> column) {
        column.setCellFactory(tc -> {
            TableCell<GetDepotDetailOutData, String> cell = new TableCell<GetDepotDetailOutData, String>(){

                protected void updateItem(String chuzhi, boolean empty) {
                    super.updateItem(chuzhi, empty);
                    if (empty) {
                        this.setGraphic(null);
                    } else {
                        Text text = new Text();
                        text.setText(chuzhi);
                        this.setGraphic((Node)text);
                    }
                }
            };
            return cell;
        });
    }

    public void changeToTextFieldDEdit(TableColumn<GetDepotDetailOutData, String> column) {
        column.setCellFactory(tc -> {
            final TextField textField = new TextField();
            textField.setMinHeight(30.0);
            TableCell<GetDepotDetailOutData, String> cell = new TableCell<GetDepotDetailOutData, String>(){

                protected void updateItem(String chuzhi, boolean empty) {
                    super.updateItem(chuzhi, empty);
                    if (empty) {
                        this.setGraphic(null);
                    } else {
                        textField.setText(chuzhi);
                        this.setGraphic((Node)textField);
                    }
                }
            };
            textField.textProperty().addListener(new ChangeListener(){
                final TableCell val_cell;
                final TextField val_textField;
                {
                    this.val_cell = cell;
                    this.val_textField = textField;
                }

                public void changed(ObservableValue observable, Object oldValue, Object newValue) {
                    int rank = this.val_cell.getIndex();
                    String cloumName = this.val_cell.getId();
                    String value = this.val_textField.getText();
                    GetDepotDetailOutData outData = (GetDepotDetailOutData)AddDepotController.this.observableTableList.get(rank);
                    String methodName = CommonUtil.getSetMethod(cloumName);
                    try {
                        Method method = GetDepotDetailOutData.class.getMethod(methodName, String.class);
                        method.invoke(outData, value);
                    }
                    catch (Exception ex) {
                        throw new RuntimeException("\u6ca1\u6709\u65b9\u6cd5" + methodName);
                    }
                }
            });
            return cell;
        });
    }

    public void changeToReasonComBoxEdit(TableColumn<GetDepotDetailOutData, String> column, ObservableList<KeyValue> options) {
        column.setCellFactory(tc -> {
            final ComboBox combo = new ComboBox();
            combo.setItems(options);
            combo.setEditable(false);
            combo.setMinHeight(30.0);
            this.comboxInit(combo);
            TableCell<GetDepotDetailOutData, String> cell = new TableCell<GetDepotDetailOutData, String>(){

                protected void updateItem(String chuzhi, boolean empty) {
                    super.updateItem(chuzhi, empty);
                    if (empty) {
                        this.setGraphic(null);
                    } else {
                        for (int i = 0; i < AddDepotController.this.reasonOptions.size(); ++i) {
                            if (!((KeyValue)AddDepotController.this.reasonOptions.get(i)).getName().equals(chuzhi)) continue;
                            combo.setValue(AddDepotController.this.reasonOptions.get(i));
                        }
                        this.setGraphic((Node)combo);
                    }
                }
            };
            combo.setOnAction(arg_0 -> this.lambda$null$3((TableCell)cell, combo, (ActionEvent) arg_0));
            return cell;
        });
    }

    public TableView<GetDepotDetailOutData> getTableView() {
        return this.tableView;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddSerial() {
        return this.gsrddSerial;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddProId() {
        return this.gsrddProId;
    }

    public TableColumn<GetDepotDetailOutData, String> getProName() {
        return this.proName;
    }

    public TableColumn<GetDepotDetailOutData, String> getProPrice() {
        return this.proPrice;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddBatchNo() {
        return this.gsrddBatchNo;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddBatch() {
        return this.gsrddBatch;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddValidDate() {
        return this.gsrddValidDate;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddStockQty() {
        return this.gsrddStockQty;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddRetdepQty() {
        return this.gsrddRetdepQty;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddRetdepCause() {
        return this.gsrddRetdepCause;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddStartQty() {
        return this.gsrddStartQty;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddReviseQty() {
        return this.gsrddReviseQty;
    }

    public TableColumn<GetDepotDetailOutData, String> getGsrddStockStatus() {
        return this.gsrddStockStatus;
    }

    public TableColumn<GetDepotDetailOutData, String> getProFactoryName() {
        return this.proFactoryName;
    }

    public TableColumn<GetDepotDetailOutData, String> getProPlace() {
        return this.proPlace;
    }

    public TableColumn<GetDepotDetailOutData, String> getProForm() {
        return this.proForm;
    }

    public TableColumn<GetDepotDetailOutData, String> getProUnit() {
        return this.proUnit;
    }

    public TableColumn<GetDepotDetailOutData, String> getProSpecs() {
        return this.proSpecs;
    }

    public TableColumn<GetDepotDetailOutData, String> getProRegisterNo() {
        return this.proRegisterNo;
    }

    public TextField getStoreText() {
        return this.storeText;
    }

    public TextField getStoreText1() {
        return this.storeText1;
    }

    public Button getAddBtn() {
        return this.addBtn;
    }

    public Button getSave() {
        return this.save;
    }

    public Button getPrint() {
        return this.print;
    }

    public Button getApprove1() {
        return this.approve1;
    }

    public Button getApprove2() {
        return this.approve2;
    }

    public Button getExportIn() {
        return this.exportIn;
    }

    public Button getExportOut() {
        return this.exportOut;
    }

    public AnchorPane getPane() {
        return this.pane;
    }

    public DepotController getDepotController() {
        return this.depotController;
    }

    public TipTopController getTipTopController() {
        return this.tipTopController;
    }

    public ClearProductQueryController getClearProductQueryController() {
        return this.clearProductQueryController;
    }

    public ObservableList<GetDepotDetailOutData> getObservableTableList() {
        return this.observableTableList;
    }

    public ObservableList<KeyValue> getGsegNameOptions() {
        return this.gsegNameOptions;
    }

    public ObservableList<KeyValue> getReasonOptions() {
        return this.reasonOptions;
    }

    public String getStatus() {
        return this.status;
    }

    public String getVoucherId() {
        return this.voucherId;
    }

    public void setTableView(TableView<GetDepotDetailOutData> tableView) {
        this.tableView = tableView;
    }

    public void setGsrddSerial(TableColumn<GetDepotDetailOutData, String> gsrddSerial) {
        this.gsrddSerial = gsrddSerial;
    }

    public void setGsrddProId(TableColumn<GetDepotDetailOutData, String> gsrddProId) {
        this.gsrddProId = gsrddProId;
    }

    public void setProName(TableColumn<GetDepotDetailOutData, String> proName) {
        this.proName = proName;
    }

    public void setProPrice(TableColumn<GetDepotDetailOutData, String> proPrice) {
        this.proPrice = proPrice;
    }

    public void setGsrddBatchNo(TableColumn<GetDepotDetailOutData, String> gsrddBatchNo) {
        this.gsrddBatchNo = gsrddBatchNo;
    }

    public void setGsrddBatch(TableColumn<GetDepotDetailOutData, String> gsrddBatch) {
        this.gsrddBatch = gsrddBatch;
    }

    public void setGsrddValidDate(TableColumn<GetDepotDetailOutData, String> gsrddValidDate) {
        this.gsrddValidDate = gsrddValidDate;
    }

    public void setGsrddStockQty(TableColumn<GetDepotDetailOutData, String> gsrddStockQty) {
        this.gsrddStockQty = gsrddStockQty;
    }

    public void setGsrddRetdepQty(TableColumn<GetDepotDetailOutData, String> gsrddRetdepQty) {
        this.gsrddRetdepQty = gsrddRetdepQty;
    }

    public void setGsrddRetdepCause(TableColumn<GetDepotDetailOutData, String> gsrddRetdepCause) {
        this.gsrddRetdepCause = gsrddRetdepCause;
    }

    public void setGsrddStartQty(TableColumn<GetDepotDetailOutData, String> gsrddStartQty) {
        this.gsrddStartQty = gsrddStartQty;
    }

    public void setGsrddReviseQty(TableColumn<GetDepotDetailOutData, String> gsrddReviseQty) {
        this.gsrddReviseQty = gsrddReviseQty;
    }

    public void setGsrddStockStatus(TableColumn<GetDepotDetailOutData, String> gsrddStockStatus) {
        this.gsrddStockStatus = gsrddStockStatus;
    }

    public void setProFactoryName(TableColumn<GetDepotDetailOutData, String> proFactoryName) {
        this.proFactoryName = proFactoryName;
    }

    public void setProPlace(TableColumn<GetDepotDetailOutData, String> proPlace) {
        this.proPlace = proPlace;
    }

    public void setProForm(TableColumn<GetDepotDetailOutData, String> proForm) {
        this.proForm = proForm;
    }

    public void setProUnit(TableColumn<GetDepotDetailOutData, String> proUnit) {
        this.proUnit = proUnit;
    }

    public void setProSpecs(TableColumn<GetDepotDetailOutData, String> proSpecs) {
        this.proSpecs = proSpecs;
    }

    public void setProRegisterNo(TableColumn<GetDepotDetailOutData, String> proRegisterNo) {
        this.proRegisterNo = proRegisterNo;
    }

    public void setStoreText(TextField storeText) {
        this.storeText = storeText;
    }

    public void setStoreText1(TextField storeText1) {
        this.storeText1 = storeText1;
    }

    public void setAddBtn(Button addBtn) {
        this.addBtn = addBtn;
    }

    public void setSave(Button save) {
        this.save = save;
    }

    public void setPrint(Button print) {
        this.print = print;
    }

    public void setApprove1(Button approve1) {
        this.approve1 = approve1;
    }

    public void setApprove2(Button approve2) {
        this.approve2 = approve2;
    }

    public void setExportIn(Button exportIn) {
        this.exportIn = exportIn;
    }

    public void setExportOut(Button exportOut) {
        this.exportOut = exportOut;
    }

    public void setPane(AnchorPane pane) {
        this.pane = pane;
    }

    public void setDepotController(DepotController depotController) {
        this.depotController = depotController;
    }

    public void setTipTopController(TipTopController tipTopController) {
        this.tipTopController = tipTopController;
    }

    public void setClearProductQueryController(ClearProductQueryController clearProductQueryController) {
        this.clearProductQueryController = clearProductQueryController;
    }

    public void setObservableTableList(ObservableList<GetDepotDetailOutData> observableTableList) {
        this.observableTableList = observableTableList;
    }

    public void setGsegNameOptions(ObservableList<KeyValue> gsegNameOptions) {
        this.gsegNameOptions = gsegNameOptions;
    }

    public void setReasonOptions(ObservableList<KeyValue> reasonOptions) {
        this.reasonOptions = reasonOptions;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public void setVoucherId(String voucherId) {
        this.voucherId = voucherId;
    }

    public boolean equals(Object o) {
        if (o == this) {
            return true;
        }
        if (!(o instanceof AddDepotController)) {
            return false;
        }
        AddDepotController other = (AddDepotController)o;
        if (!other.canEqual(this)) {
            return false;
        }
        TableView<GetDepotDetailOutData> this$tableView = this.getTableView();
        TableView<GetDepotDetailOutData> other$tableView = other.getTableView();
        if (this$tableView == null ? other$tableView != null : !this$tableView.equals(other$tableView)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddSerial = this.getGsrddSerial();
        TableColumn<GetDepotDetailOutData, String> other$gsrddSerial = other.getGsrddSerial();
        if (this$gsrddSerial == null ? other$gsrddSerial != null : !this$gsrddSerial.equals(other$gsrddSerial)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddProId = this.getGsrddProId();
        TableColumn<GetDepotDetailOutData, String> other$gsrddProId = other.getGsrddProId();
        if (this$gsrddProId == null ? other$gsrddProId != null : !this$gsrddProId.equals(other$gsrddProId)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proName = this.getProName();
        TableColumn<GetDepotDetailOutData, String> other$proName = other.getProName();
        if (this$proName == null ? other$proName != null : !this$proName.equals(other$proName)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proPrice = this.getProPrice();
        TableColumn<GetDepotDetailOutData, String> other$proPrice = other.getProPrice();
        if (this$proPrice == null ? other$proPrice != null : !this$proPrice.equals(other$proPrice)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddBatchNo = this.getGsrddBatchNo();
        TableColumn<GetDepotDetailOutData, String> other$gsrddBatchNo = other.getGsrddBatchNo();
        if (this$gsrddBatchNo == null ? other$gsrddBatchNo != null : !this$gsrddBatchNo.equals(other$gsrddBatchNo)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddBatch = this.getGsrddBatch();
        TableColumn<GetDepotDetailOutData, String> other$gsrddBatch = other.getGsrddBatch();
        if (this$gsrddBatch == null ? other$gsrddBatch != null : !this$gsrddBatch.equals(other$gsrddBatch)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddValidDate = this.getGsrddValidDate();
        TableColumn<GetDepotDetailOutData, String> other$gsrddValidDate = other.getGsrddValidDate();
        if (this$gsrddValidDate == null ? other$gsrddValidDate != null : !this$gsrddValidDate.equals(other$gsrddValidDate)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddStockQty = this.getGsrddStockQty();
        TableColumn<GetDepotDetailOutData, String> other$gsrddStockQty = other.getGsrddStockQty();
        if (this$gsrddStockQty == null ? other$gsrddStockQty != null : !this$gsrddStockQty.equals(other$gsrddStockQty)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddRetdepQty = this.getGsrddRetdepQty();
        TableColumn<GetDepotDetailOutData, String> other$gsrddRetdepQty = other.getGsrddRetdepQty();
        if (this$gsrddRetdepQty == null ? other$gsrddRetdepQty != null : !this$gsrddRetdepQty.equals(other$gsrddRetdepQty)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddRetdepCause = this.getGsrddRetdepCause();
        TableColumn<GetDepotDetailOutData, String> other$gsrddRetdepCause = other.getGsrddRetdepCause();
        if (this$gsrddRetdepCause == null ? other$gsrddRetdepCause != null : !this$gsrddRetdepCause.equals(other$gsrddRetdepCause)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddStartQty = this.getGsrddStartQty();
        TableColumn<GetDepotDetailOutData, String> other$gsrddStartQty = other.getGsrddStartQty();
        if (this$gsrddStartQty == null ? other$gsrddStartQty != null : !this$gsrddStartQty.equals(other$gsrddStartQty)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddReviseQty = this.getGsrddReviseQty();
        TableColumn<GetDepotDetailOutData, String> other$gsrddReviseQty = other.getGsrddReviseQty();
        if (this$gsrddReviseQty == null ? other$gsrddReviseQty != null : !this$gsrddReviseQty.equals(other$gsrddReviseQty)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$gsrddStockStatus = this.getGsrddStockStatus();
        TableColumn<GetDepotDetailOutData, String> other$gsrddStockStatus = other.getGsrddStockStatus();
        if (this$gsrddStockStatus == null ? other$gsrddStockStatus != null : !this$gsrddStockStatus.equals(other$gsrddStockStatus)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proFactoryName = this.getProFactoryName();
        TableColumn<GetDepotDetailOutData, String> other$proFactoryName = other.getProFactoryName();
        if (this$proFactoryName == null ? other$proFactoryName != null : !this$proFactoryName.equals(other$proFactoryName)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proPlace = this.getProPlace();
        TableColumn<GetDepotDetailOutData, String> other$proPlace = other.getProPlace();
        if (this$proPlace == null ? other$proPlace != null : !this$proPlace.equals(other$proPlace)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proForm = this.getProForm();
        TableColumn<GetDepotDetailOutData, String> other$proForm = other.getProForm();
        if (this$proForm == null ? other$proForm != null : !this$proForm.equals(other$proForm)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proUnit = this.getProUnit();
        TableColumn<GetDepotDetailOutData, String> other$proUnit = other.getProUnit();
        if (this$proUnit == null ? other$proUnit != null : !this$proUnit.equals(other$proUnit)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proSpecs = this.getProSpecs();
        TableColumn<GetDepotDetailOutData, String> other$proSpecs = other.getProSpecs();
        if (this$proSpecs == null ? other$proSpecs != null : !this$proSpecs.equals(other$proSpecs)) {
            return false;
        }
        TableColumn<GetDepotDetailOutData, String> this$proRegisterNo = this.getProRegisterNo();
        TableColumn<GetDepotDetailOutData, String> other$proRegisterNo = other.getProRegisterNo();
        if (this$proRegisterNo == null ? other$proRegisterNo != null : !this$proRegisterNo.equals(other$proRegisterNo)) {
            return false;
        }
        TextField this$storeText = this.getStoreText();
        TextField other$storeText = other.getStoreText();
        if (this$storeText == null ? other$storeText != null : !this$storeText.equals(other$storeText)) {
            return false;
        }
        TextField this$storeText1 = this.getStoreText1();
        TextField other$storeText1 = other.getStoreText1();
        if (this$storeText1 == null ? other$storeText1 != null : !this$storeText1.equals(other$storeText1)) {
            return false;
        }
        Button this$addBtn = this.getAddBtn();
        Button other$addBtn = other.getAddBtn();
        if (this$addBtn == null ? other$addBtn != null : !this$addBtn.equals(other$addBtn)) {
            return false;
        }
        Button this$save = this.getSave();
        Button other$save = other.getSave();
        if (this$save == null ? other$save != null : !this$save.equals(other$save)) {
            return false;
        }
        Button this$print = this.getPrint();
        Button other$print = other.getPrint();
        if (this$print == null ? other$print != null : !this$print.equals(other$print)) {
            return false;
        }
        Button this$approve1 = this.getApprove1();
        Button other$approve1 = other.getApprove1();
        if (this$approve1 == null ? other$approve1 != null : !this$approve1.equals(other$approve1)) {
            return false;
        }
        Button this$approve2 = this.getApprove2();
        Button other$approve2 = other.getApprove2();
        if (this$approve2 == null ? other$approve2 != null : !this$approve2.equals(other$approve2)) {
            return false;
        }
        Button this$exportIn = this.getExportIn();
        Button other$exportIn = other.getExportIn();
        if (this$exportIn == null ? other$exportIn != null : !this$exportIn.equals(other$exportIn)) {
            return false;
        }
        Button this$exportOut = this.getExportOut();
        Button other$exportOut = other.getExportOut();
        if (this$exportOut == null ? other$exportOut != null : !this$exportOut.equals(other$exportOut)) {
            return false;
        }
        AnchorPane this$pane = this.getPane();
        AnchorPane other$pane = other.getPane();
        if (this$pane == null ? other$pane != null : !this$pane.equals(other$pane)) {
            return false;
        }
        DepotController this$depotController = this.getDepotController();
        DepotController other$depotController = other.getDepotController();
        if (this$depotController == null ? other$depotController != null : !(this$depotController).equals(other$depotController)) {
            return false;
        }
        TipTopController this$tipTopController = this.getTipTopController();
        TipTopController other$tipTopController = other.getTipTopController();
        if (this$tipTopController == null ? other$tipTopController != null : !(this$tipTopController).equals(other$tipTopController)) {
            return false;
        }
        ClearProductQueryController this$clearProductQueryController = this.getClearProductQueryController();
        ClearProductQueryController other$clearProductQueryController = other.getClearProductQueryController();
        if (this$clearProductQueryController == null ? other$clearProductQueryController != null : !(this$clearProductQueryController).equals(other$clearProductQueryController)) {
            return false;
        }
        ObservableList<GetDepotDetailOutData> this$observableTableList = this.getObservableTableList();
        ObservableList<GetDepotDetailOutData> other$observableTableList = other.getObservableTableList();
        if (this$observableTableList == null ? other$observableTableList != null : !this$observableTableList.equals(other$observableTableList)) {
            return false;
        }
        ObservableList<KeyValue> this$gsegNameOptions = this.getGsegNameOptions();
        ObservableList<KeyValue> other$gsegNameOptions = other.getGsegNameOptions();
        if (this$gsegNameOptions == null ? other$gsegNameOptions != null : !this$gsegNameOptions.equals(other$gsegNameOptions)) {
            return false;
        }
        ObservableList<KeyValue> this$reasonOptions = this.getReasonOptions();
        ObservableList<KeyValue> other$reasonOptions = other.getReasonOptions();
        if (this$reasonOptions == null ? other$reasonOptions != null : !this$reasonOptions.equals(other$reasonOptions)) {
            return false;
        }
        String this$status = this.getStatus();
        String other$status = other.getStatus();
        if (this$status == null ? other$status != null : !this$status.equals(other$status)) {
            return false;
        }
        String this$voucherId = this.getVoucherId();
        String other$voucherId = other.getVoucherId();
        return !(this$voucherId == null ? other$voucherId != null : !this$voucherId.equals(other$voucherId));
    }

    protected boolean canEqual(Object other) {
        return other instanceof AddDepotController;
    }

    public int hashCode() {
        int PRIME = 59;
        int result = 1;
        TableView<GetDepotDetailOutData> $tableView = this.getTableView();
        result = result * 59 + ($tableView == null ? 43 : $tableView.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddSerial = this.getGsrddSerial();
        result = result * 59 + ($gsrddSerial == null ? 43 : $gsrddSerial.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddProId = this.getGsrddProId();
        result = result * 59 + ($gsrddProId == null ? 43 : $gsrddProId.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proName = this.getProName();
        result = result * 59 + ($proName == null ? 43 : $proName.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proPrice = this.getProPrice();
        result = result * 59 + ($proPrice == null ? 43 : $proPrice.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddBatchNo = this.getGsrddBatchNo();
        result = result * 59 + ($gsrddBatchNo == null ? 43 : $gsrddBatchNo.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddBatch = this.getGsrddBatch();
        result = result * 59 + ($gsrddBatch == null ? 43 : $gsrddBatch.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddValidDate = this.getGsrddValidDate();
        result = result * 59 + ($gsrddValidDate == null ? 43 : $gsrddValidDate.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddStockQty = this.getGsrddStockQty();
        result = result * 59 + ($gsrddStockQty == null ? 43 : $gsrddStockQty.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddRetdepQty = this.getGsrddRetdepQty();
        result = result * 59 + ($gsrddRetdepQty == null ? 43 : $gsrddRetdepQty.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddRetdepCause = this.getGsrddRetdepCause();
        result = result * 59 + ($gsrddRetdepCause == null ? 43 : $gsrddRetdepCause.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddStartQty = this.getGsrddStartQty();
        result = result * 59 + ($gsrddStartQty == null ? 43 : $gsrddStartQty.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddReviseQty = this.getGsrddReviseQty();
        result = result * 59 + ($gsrddReviseQty == null ? 43 : $gsrddReviseQty.hashCode());
        TableColumn<GetDepotDetailOutData, String> $gsrddStockStatus = this.getGsrddStockStatus();
        result = result * 59 + ($gsrddStockStatus == null ? 43 : $gsrddStockStatus.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proFactoryName = this.getProFactoryName();
        result = result * 59 + ($proFactoryName == null ? 43 : $proFactoryName.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proPlace = this.getProPlace();
        result = result * 59 + ($proPlace == null ? 43 : $proPlace.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proForm = this.getProForm();
        result = result * 59 + ($proForm == null ? 43 : $proForm.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proUnit = this.getProUnit();
        result = result * 59 + ($proUnit == null ? 43 : $proUnit.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proSpecs = this.getProSpecs();
        result = result * 59 + ($proSpecs == null ? 43 : $proSpecs.hashCode());
        TableColumn<GetDepotDetailOutData, String> $proRegisterNo = this.getProRegisterNo();
        result = result * 59 + ($proRegisterNo == null ? 43 : $proRegisterNo.hashCode());
        TextField $storeText = this.getStoreText();
        result = result * 59 + ($storeText == null ? 43 : $storeText.hashCode());
        TextField $storeText1 = this.getStoreText1();
        result = result * 59 + ($storeText1 == null ? 43 : $storeText1.hashCode());
        Button $addBtn = this.getAddBtn();
        result = result * 59 + ($addBtn == null ? 43 : $addBtn.hashCode());
        Button $save = this.getSave();
        result = result * 59 + ($save == null ? 43 : $save.hashCode());
        Button $print = this.getPrint();
        result = result * 59 + ($print == null ? 43 : $print.hashCode());
        Button $approve1 = this.getApprove1();
        result = result * 59 + ($approve1 == null ? 43 : $approve1.hashCode());
        Button $approve2 = this.getApprove2();
        result = result * 59 + ($approve2 == null ? 43 : $approve2.hashCode());
        Button $exportIn = this.getExportIn();
        result = result * 59 + ($exportIn == null ? 43 : $exportIn.hashCode());
        Button $exportOut = this.getExportOut();
        result = result * 59 + ($exportOut == null ? 43 : $exportOut.hashCode());
        AnchorPane $pane = this.getPane();
        result = result * 59 + ($pane == null ? 43 : $pane.hashCode());
        DepotController $depotController = this.getDepotController();
        result = result * 59 + ($depotController == null ? 43 : ($depotController).hashCode());
        TipTopController $tipTopController = this.getTipTopController();
        result = result * 59 + ($tipTopController == null ? 43 : ($tipTopController).hashCode());
        ClearProductQueryController $clearProductQueryController = this.getClearProductQueryController();
        result = result * 59 + ($clearProductQueryController == null ? 43 : ($clearProductQueryController).hashCode());
        ObservableList<GetDepotDetailOutData> $observableTableList = this.getObservableTableList();
        result = result * 59 + ($observableTableList == null ? 43 : $observableTableList.hashCode());
        ObservableList<KeyValue> $gsegNameOptions = this.getGsegNameOptions();
        result = result * 59 + ($gsegNameOptions == null ? 43 : $gsegNameOptions.hashCode());
        ObservableList<KeyValue> $reasonOptions = this.getReasonOptions();
        result = result * 59 + ($reasonOptions == null ? 43 : $reasonOptions.hashCode());
        String $status = this.getStatus();
        result = result * 59 + ($status == null ? 43 : $status.hashCode());
        String $voucherId = this.getVoucherId();
        result = result * 59 + ($voucherId == null ? 43 : $voucherId.hashCode());
        return result;
    }

    public String toString() {
        return "AddDepotController(tableView=" + this.getTableView() + ", gsrddSerial=" + this.getGsrddSerial() + ", gsrddProId=" + this.getGsrddProId() + ", proName=" + this.getProName() + ", proPrice=" + this.getProPrice() + ", gsrddBatchNo=" + this.getGsrddBatchNo() + ", gsrddBatch=" + this.getGsrddBatch() + ", gsrddValidDate=" + this.getGsrddValidDate() + ", gsrddStockQty=" + this.getGsrddStockQty() + ", gsrddRetdepQty=" + this.getGsrddRetdepQty() + ", gsrddRetdepCause=" + this.getGsrddRetdepCause() + ", gsrddStartQty=" + this.getGsrddStartQty() + ", gsrddReviseQty=" + this.getGsrddReviseQty() + ", gsrddStockStatus=" + this.getGsrddStockStatus() + ", proFactoryName=" + this.getProFactoryName() + ", proPlace=" + this.getProPlace() + ", proForm=" + this.getProForm() + ", proUnit=" + this.getProUnit() + ", proSpecs=" + this.getProSpecs() + ", proRegisterNo=" + this.getProRegisterNo() + ", storeText=" + this.getStoreText() + ", storeText1=" + this.getStoreText1() + ", addBtn=" + this.getAddBtn() + ", save=" + this.getSave() + ", print=" + this.getPrint() + ", approve1=" + this.getApprove1() + ", approve2=" + this.getApprove2() + ", exportIn=" + this.getExportIn() + ", exportOut=" + this.getExportOut() + ", pane=" + this.getPane() + ", depotController=" + this.getDepotController() + ", tipTopController=" + this.getTipTopController() + ", clearProductQueryController=" + this.getClearProductQueryController() + ", observableTableList=" + this.getObservableTableList() + ", gsegNameOptions=" + this.getGsegNameOptions() + ", reasonOptions=" + this.getReasonOptions() + ", status=" + this.getStatus() + ", voucherId=" + this.getVoucherId() + ")";
    }

    private void lambda$null$3(TableCell cell, ComboBox combo, ActionEvent e) {
        int rank = cell.getIndex();
        String cloumName = cell.getId();
        String value = ((KeyValue)combo.getValue()).getValue();
        String name = ((KeyValue)combo.getValue()).getName();
        GetDepotDetailOutData outData = (GetDepotDetailOutData)this.observableTableList.get(rank);
        String methodName = CommonUtil.getSetMethod(cloumName);
        try {
            Method method = GetDepotDetailOutData.class.getMethod(methodName, String.class);
            method.invoke(outData, value);
        }
        catch (Exception ex) {
            throw new RuntimeException("\u6ca1\u6709\u65b9\u6cd5" + methodName);
        }
    }
}

